<?php

/**
 * Autoload 
 * Carrega automaticamente as classes que estao em model 
 * @param unknown $className
 * @name MyAutoload
 */
function MyAutoload($className){
	require_once("models/".$className . '.php');
}

//inicia session
if(empty($_SESSION)){
    session_start();
}
// Next, register it with PHP.
spl_autoload_register('MyAutoload');
//define diretorios 
define(DIRROOT, realpath(dirname(__FILE__)));
define(DIRVIEWS, realpath(dirname(__FILE__))."/views/");

//cria a classe com as option de conficuracao 
$opitions = include DIRROOT.'/con.php';


Options::setAll($opitions);



